Linux vbd hotplug: Avoid "leaked" loopback devices
authorKeir Fraser <keir.fraser@citrix.com>
Tue, 3 Nov 2009 08:38:55 +0000 (08:38 +0000)
committerKeir Fraser <keir.fraser@citrix.com>
Tue, 3 Nov 2009 08:38:55 +0000 (08:38 +0000)
commit92e6cb5673b37bd883bdef0d0e83faf000edf61d
treef6b955bd8158b41a7d0ffb421fdb3fccd480e0c7
parent45c3fa3c2d40933a1e44218525eb3756014a88a1
Linux vbd hotplug: Avoid "leaked" loopback devices

Avoid races between hotplug "add" and "remove" leading to "leaked"
loopback devices.

- Don't setup loopback device if xend is no longer waiting for the
  vbd.
- Use the lock file to avoid add/remove races.

Signed-off-by: Gary Grebus <gary.grebus@oracle.com>
tools/hotplug/Linux/block